#include "Triangle.h"

namespace baker
{
    //--------------------------------------------------------------------------
    Triangle::Triangle( const Vec3 & v0
                      , const Vec3 & v1
                      , const Vec3 & v2
                      )
    {
        v[0] = v0;
        v[1] = v1;
        v[2] = v2;
    }

    //--------------------------------------------------------------------------
    Vec3 Triangle::getNormal() const
    {
        return normalizedCopy( cross( v[1] - v[0], v[2] - v[0] ) );
    }

    //--------------------------------------------------------------------------
    //--------------------------------------------------------------------------
    //--------------------------------------------------------------------------

}
